﻿using System;
using System.Collections.Generic;

namespace TradeMeSDK
{
    public partial class Listings
    {
        public int TotalCount { get; set; }
        public int Page { get; set; }
        public int PageSize { get; set; }
        public List<ListedItemDetail> List { get; set; }
    }

    public partial class Listing
    {
        public int ListingId { get; set; }
        public string Title { get; set; }
        public string Category { get; set; }
        public decimal StartPrice { get; set; }
        public decimal BuyNowPrice { get; set; }
        public DateTime StartDate { get; set; }
        public DateTime EndDate { get; set; }
        public bool IsFeatured { get; set; }
        public bool HasGallery { get; set; }
        public bool IsBold { get; set; }
        public bool IsHighlighted { get; set; }
        public bool HasHomePageFeature { get; set; }
        public bool HasExtraPhotos { get; set; }
        public bool HasScheduledEndDate { get; set; }
        public int BidderAndWatchers { get; set; }
        public decimal MaxBidAmount { get; set; }
        public DateTime AsAt { get; set; }
        public string CategoryPath { get; set; }
        public string PictureHref { get; set; }
        public int PhotoId { get; set; }
        public bool HasPayNow { get; set; }
        public bool IsNew { get; set; }
        public int RegionId { get; set; }
        public string Region { get; set; }
        public int SuburbId { get; set; }
        public string Suburb { get; set; }
        public int BidCount { get; set; }
        public int ViewCount { get; set; }
        public bool IsReserveMet { get; set; }
        public bool HasReserve { get; set; }
        public bool HasBuyNow { get; set; }
        public DateTime NoteDate { get; set; }
        public string CategoryName { get; set; }
        public string ReserveState { get; set; }
        public List<Attribute> Attributes { get; set; }
        public bool IsClassified { get; set; }
        public bool IsOnWatchList { get; set; }
    }

    public class Attribute
    {
        public string Name { get; set; }
        public string DisplayName { get; set; }
        public string Value { get; set; }
    }

    public class Photo
    {
        public int PhotoId { get; set; }
        public PhotoValue Value { get; set; }
    }

    public class PhotoValue
    {
        public int PhotoId { get; set; }
        public string Thumbnail { get; set; }
        public string List { get; set; }
        public string Medium { get; set; }
        public string Gallery { get; set; }
        public string Large { get; set; }
        public string FullSize { get; set; }
    }

    public class ShippingOption
    {
        public int ShippingId { get; set; }
        public string Type { get; set; }
        public double Price { get; set; }
        public string Method { get; set; }
    }

    public class OpenHome
    {
        public DateTime Start { get; set; }
        public DateTime End { get; set; }
    }

    public class Agent
    {
        public string FullName { get; set; }
        public string Position { get; set; }
        public string MobilePhoneNumber { get; set; }
        public string OfficePhoneNumber { get; set; }
        public string EMail { get; set; }
        public string FaxNumber { get; set; }
        public string HomePhoneNumber { get; set; }
        public string FirstName { get; set; }
    }

    public class Agency
    {
        public int Id { get; set; }
        public string Name { get; set; }
        public string Address { get; set; }
        public string Suburb { get; set; }
        public string City { get; set; }
        public string PhoneNumber { get; set; }
        public string FaxNumber { get; set; }
        public string EMail { get; set; }
        public string Website { get; set; }
        public string Logo { get; set; }
        public int Type { get; set; }
        public int BillingType { get; set; }
        public List<Agent> Agents { get; set; }
        public bool IsRealEstateAgency { get; set; }
        public bool IsJobAgency { get; set; }
    }

    public class Bid
    {
        public string Account { get; set; }
        public double BidAmount { get; set; }
        public bool IsByMobile { get; set; }
        public bool IsByProxy { get; set; }
        public DateTime BidDate { get; set; }
        public bool IsBuyNow { get; set; }
        public Member Bidder { get; set; }
    }

    public class Bids
    {
        public int TotalCount { get; set; }
        public int Page { get; set; }
        public int PageSize { get; set; }
        public List<Bid> List { get; set; }
    }

    public class Question
    {
        public int ListingId { get; set; }
        public int ListingQuestionId { get; set; }
        public string Comment { get; set; }
        public DateTime CommentDate { get; set; }
        public bool IsSellerComment { get; set; }
        public string Answer { get; set; }
        public DateTime AnswerDate { get; set; }
        public Member AskingMember { get; set; }
    }

    public class Questions
    {
        public int TotalCount { get; set; }
        public int Page { get; set; }
        public int PageSize { get; set; }
        public List<Question> List { get; set; }
    }


    public class Dealership
    {
        public int Id { get; set; }
        public string Name { get; set; }
        public string Address { get; set; }
        public string Suburb { get; set; }
        public string City { get; set; }
        public string PhoneNumber { get; set; }
        public string FaxNumber { get; set; }
        public string EMail { get; set; }
        public string Website { get; set; }
        public string Logo { get; set; }
        public int Type { get; set; }
        public int BillingType { get; set; }
        public List<Dealer> Dealers { get; set; }
    }

    public class Dealer
    {
        public string FullName { get; set; }
        public string Position { get; set; }
        public string MobilePhoneNumber { get; set; }
        public string OfficePhoneNumber { get; set; }
        public string EMail { get; set; }
        public string FaxNumber { get; set; }
        public string HomePhoneNumber { get; set; }
    }

    public class GeographicLocation
    {
        public decimal Latitude { get; set; }
        public decimal Longitude { get; set; }
    }

    public class ListedItemDetail
    {
        public int ListingId { get; set; }
        public string Title { get; set; }
        public string Category { get; set; }
        public string PriceDisplay { get; set; }
        public decimal StartPrice { get; set; }
        public decimal BuyNowPrice { get; set; }
        public DateTime StartDate { get; set; }
        public DateTime EndDate { get; set; }
        //  <ListingLength i:nil="true"/>
        //  <Restrictions i:nil="true"/>
        public bool IsFeatured { get; set; }
        public bool HasGallery { get; set; }
        public bool IsBold { get; set; }
        public bool IsHighlighted { get; set; }
        public bool HasHomePageFeature { get; set; }
        public bool HasExtraPhotos { get; set; }
        public bool HasScheduledEndDate { get; set; }
        public int BidderAndWatchers { get; set; }
        public decimal MaxBidAmount { get; set; }
        public DateTime AsAt { get; set; }
        public string CategoryPath { get; set; }
        public string PictureHref { get; set; }
        public int PhotoId { get; set; }
        //  <Seller i:nil="true"/>
        public bool HasPayNow { get; set; }
        public bool IsNew { get; set; }
        public int RegionId { get; set; }
        public string Region { get; set; }
        public int SuburbId { get; set; }
        public string Suburb { get; set; }
        public int BidCount { get; set; }
        public int ViewCount { get; set; }
        public bool IsReserveMet { get; set; }
        public bool HasReserve { get; set; }
        public bool HasBuyNow { get; set; }
        public DateTime NoteDate { get; set; }
        public string CategoryName { get; set; }
        public string ReserveState { get; set; }
        public List<Attribute> Attributes { get; set; }
        public bool IsClassified { get; set; }
        public bool IsOnWatchList { get; set; }
        public List<OpenHome> OpenHomes { get; set; }
        public Member Member { get; set; }
        public string Body { get; set; }
        public Bids Bids { get; set; }
        public Questions Questions { get; set; }
        public List<Photo> Photos { get; set; }
        public string AllowsPickups { get; set; }
        public List<ShippingOption> ShippingOptions { get; set; }
        public string PaymentOptions { get; set; }
        public Dealership Dealership { get; set; }
		public Agency Agency { get; set; }

        public string District { get; set; }
        public string JobType { get; set; }
        public string PayBenefits { get; set; }
        public string Reference { get; set; }
        public string ApplicationDetails { get; set; }
        public bool IsWorkPermitRequired { get; set; }
        public string Instructions { get; set; }
        // Listed
        // Keywords
        // JobCategory
        // JobSubcategory
        public string Company { get; set; }
        public string JobLocation { get; set; }
        public string ContractLength { get; set; }
        public string PayType { get; set; }
        public string JobPackId { get; set; }
        public string Address { get; set; }
        public string AgencyReference { get; set; }
        public string Amenities { get; set; }
        public int Area { get; set; }
        public int LandArea { get; set; }
        public string AvailableFrom { get; set; }
        public int Bathrooms { get; set; }
        public int Bedrooms { get; set; }
        public string BestContactTime { get; set; }
        //Details
        public string IdealTenant { get; set; }
        public string Keywords { get; set; }
        public string ListingGroup { get; set; }
        public int MaxTenants { get; set; }
        public string Parking { get; set; }
        public string ParkingOrGaraging { get; set; }
        public bool Pets { get; set; }
        public string PropertyType { get; set; }
        public int RateableValue { get; set; }
        public decimal RentPerWeek { get; set; }
        public bool Smokers { get; set; }
        public string ViewingInstructions { get; set; }
        public string Whiteware { get; set; }
        public string PropertyId { get; set; }
        public GeographicLocation GeographicLocation { get; set; }

        public List<string> AdjacentSuburbNames { get; set; }
        public List<int> AdjacentSuburbIds { get; set; }
        public int DistrictId { get; set; }
        public Agent Agent { get; set; }
    }




    public class TradeMeResult
    {
        public bool Success { get; set; }
        public string Description { get; set; }
    }
}
